import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';

class WelcomePage extends StatelessWidget {
  const WelcomePage({super.key,required this.onPressed});
  final VoidCallback onPressed;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
        backgroundColor: Color.fromRGBO(24, 24, 24, 1),
        body: Container(
          alignment: Alignment.center,
          child: Column(
            mainAxisAlignment: MainAxisAlignment.center,
            crossAxisAlignment: CrossAxisAlignment.center,
            children: [
              Image.asset(
                "assets/imgs/img_welcome.png",
                width: 262.w,
                height: 195.h,
              ),
              Container(
                width: 80.w,
                height: 40.h,
                margin: EdgeInsets.only(top: 20.h),
                child: TextButton(
                  onPressed: () {
                    onPressed.call();
                  },
                  style: TextButton.styleFrom(backgroundColor: Color.fromRGBO(215, 48, 48, 1)),
                  child: Text(
                    "Let's Go!",
                    style: TextStyle(
                      color: Colors.white,
                      fontSize: 12.sp,
                      fontWeight: FontWeight.w600,
                    ),
                    textScaler: TextScaler.noScaling,
                  ),
                ),
              )
            ],
          ),
        ));
  }
}
